<template>
   <el-table :data="evaluatelist" border style="width: 100%" :height="curHeight" v-loadMore="[payLoads,'evalutelist']">
         <el-table-column  label="头像"  width="80">
           <template slot-scope="{row}">

              <img :src="row.avatar?row.avatar:'http://cdn.rzico.com/img/qqq.jpg'" style="width:25px;height:25px;border-radius:50%;" alt="">
           </template>
         </el-table-column>
         <el-table-column prop="orderSn" label="订单号"  width="120"></el-table-column>
         <el-table-column prop="nickname" label="评价账号"  width="120"></el-table-column>
         <el-table-column prop="star" label="评价星级"  width="80"></el-table-column>
         <el-table-column prop="name" label="商品名称"  width="280"></el-table-column>
         <el-table-column prop="content" label="评价内容" ></el-table-column>
         <el-table-column prop="createDate" label="评价日期"  width="180">
           <template slot-scope="{row}">
             <span>{{row.createDate|datetimeFormatter}}</span>
           </template>
         </el-table-column>
         
        
     </el-table>
     
     
</template>

<script>
import { array } from 'jszip/lib/support'

import { number } from 'echarts/lib/export';
import data from '@/views/evaluationOrder/content';
import loadMore from "@/utils/more.js";
export default {
  directives: { loadMore },
   data() {
      return {
        pageNum: 1,
        pageSize: 20,
        payLoads:0,
        curHeight:''
      }
    },
    activated() {
    this.payLoads = new Date().getTime();
  },
  props: {
    evaluatelist: {
      type: array,
      default: []
    },
    total:{
      type:Number,
      default:0
    }
  },
    mounted() {
    this.comeIn()
    this.beforeMount()
  },
  methods: {
       beforeMount() {
      window.onresize = () => {
        return (() => {
          if (this.queryType == false) {
            var h = document.documentElement.clientHeight || document.body.clientHeight
            this.curHeight = h - 336// 减去页面上固定高度height
          } else {
            var h = document.documentElement.clientHeight || document.body.clientHeight
            this.curHeight = h - 290// 减去页面上固定高度height
          }
        })()
      }
    },
    comeIn() {
      console.log('222')
      var h = document.documentElement.clientHeight || document.body.clientHeight
      this.curHeight = h - 290// 减去页面上固定高度height
    },
  }

}
</script>

<style lang="scss" scoped>
</style>
